#include "playscene.h"
#include "QPainter"
#include <QPushButton>
#include "player.h"
PlayScene::PlayScene(QWidget *parent) : QMainWindow(parent)
{
    this->setFixedSize(1200,900);
    this->setWindowIcon(QIcon(":/images/monster_up.png"));
    this->setWindowTitle("喵斯快跑");




}
void PlayScene::paintEvent(QPaintEvent *)
{
    QPainter painter(this);
    QPixmap pix;
    pix.load(":/images/bk1.jpg");
    painter.drawPixmap(0,0,this->width(),this->height(),pix);
    pix.load(":/images/run0.png");
    painter.drawPixmap(25,this->height()-pix.height()-25,pix);
    for(int i=0;i<6;i++)
    {
        QString str = QString(":/images/run%1.png").arg(this->min++);
        pix.load(str);
        painter.drawPixmap(25,this->height()-pix.height()-25,pix);
    }
}
